package com.phoenix.sgs.faq;

import java.util.List;

import com.phoenix.sgs.faq.adapter.FAQAdapter;
import com.phoenix.sgs.faq.general.FAQ;
import com.phoenix.sgs.faq.general.GeneralHelper;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.widget.ListView;

public class GeneralFAQActivity extends Activity {
	@Override
    public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
        this.setContentView(R.layout.generalfaq);
        
        Intent intent = this.getIntent();
    	int skillId = intent.getIntExtra("SelectedId", 0);
    	
    	ListView lvFAQs = (ListView) findViewById(R.id.listViewFaqs);
    	List<FAQ> faqs = GeneralHelper.getFAQ4General(this, skillId);
    	FAQAdapter faqAdapter = new FAQAdapter(this, faqs);
    	lvFAQs.setAdapter(faqAdapter);
	}
}
